package com.woniuxy.student.provider.service.impl;

import com.woniuxy.entity.Student;
import com.woniuxy.student.provider.mapper.StudentMapper;
import com.woniuxy.student.provider.service.StudentService;
import jdk.jfr.TransitionFrom;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Isolation;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author 作者
 * @create 2025-06-26 12:10
 */
@Service
public class StudentServiceImpl implements StudentService {



    @Autowired
    StudentMapper studentMapper;

    @Override
    public void add(Student student) {
        studentMapper.insert(student);
    }

    @Override
    public Student getBySid(int sid) {
        return studentMapper.selectBySid(sid);
    }

    @Override
    public List<Student> getAll() {
        return studentMapper.selectAll();
    }
}
